package ch.ebnoether.wuerfel;

import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;

import ch.ebnoether.gui.YatzyGUI;

public class DiceListener extends MouseAdapter {

  /*
     * (non-Javadoc)
     *
     * @see java.awt.event.MouseAdapter#mouseClicked(java.awt.event.MouseEvent)
     */
  @Override
  public void mouseClicked(MouseEvent e) {
    Object o = e.getSource();
    Dice d = (Dice) o;

    if (YatzyGUI.diceingRestNumber < 3) {
      d.changeStatus();
    }
  }



}
